<form class="form-horizontal" id="form-add-category">
    <input type="hidden" name="cid" value="{$info.id}">
    <div class="form-group">
        <label class="control-label col-xs-2">
            地区名称
        </label>
        <div class="col-xs-9">
            <input type="text" class="form-control" name="title" placeholder="输入地区名称" value="{$info.title}" readonly>
        </div>
    </div>

    <div class="form-group">
        <label class="control-label col-xs-2">
            地区级别
        </label>
        <div class="col-xs-9">
            {if condition="$info.level == 1"}
            <input type="text" class="form-control" name="level"  value="省级/直辖市" readonly>
            {/if}
            {if condition="$info.level == 2"}
            <input type="text" class="form-control" name="level"  value="市级" readonly>
            {/if}
        </div>
    </div>

    <div class="form-group">
        <label class="control-label col-xs-2">地区排序</label>
        <div class="col-xs-9">
            <input type="number" class="form-control" name="order" value="{$info.order_num}"
                   placeholder="输入地区排序号，序号越高，显示越靠前">
        </div>
    </div>



    <div class="form-group">
        <div class="col-xs-offset-2 col-xs-3">
            <button type="submit" class="btn btn-success btn-block">确认修改</button>
        </div>
    </div>
</form>

<script src="__PUBLIC__/vendors/jquery.validation/jquery.validate.min.js"></script>
<script src="__PUBLIC__/vendors/jquery.validation/additional-methods.js"></script>
<script src="__PUBLIC__/vendors/jquery.validation/messages_zh.min.js"></script>
<script type="application/javascript">
    $(function () {
        $("#form-add-category").validate({
            messages:
                {

                },
            debug: true,
            submitHandler: function () {

                ajaxSubmit('form-add-category', true);
            }
        });
    })
</script>